﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Template.Master" Inherits="System.Web.Mvc.ViewPage<JLL.China.Web.Areas.Portal.Models.AdminModel>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">
    <!--  start page-heading -->
    <div id="page-heading">
        <h1>
           Profile
        </h1>
    </div>
  <!-- end page-heading -->
   <table border="0" width="100%" cellpadding="0" cellspacing="0" id="content-table">
        <tr>
            <th rowspan="3" class="sized">
                <img src="<%=Url.Content("~/Content/images/shared/side_shadowleft.jpg")%>" width="20"
                    height="300" alt="" />
            </th>
            <th class="topleft">
            </th>
            <td id="tbl-border-top">
                &nbsp;
            </td>
            <th class="topright">
            </th>
            <th rowspan="3" class="sized">
                <img src="<%=Url.Content("~/Content/images/shared/side_shadowright.jpg")%>" width="20"
                    height="300" alt="" />
            </th>
        </tr>
        <tr>
            <td id="tbl-border-left">
            </td>
            <td>
                <!--  start content-table-inner ...................................................................... START -->
                <div id="content-table-inner">
                    <% Html.RenderPartial("Measage");%>
                    
                    <!--  start step-holder -->
    <div id="step-holder">
        <div class="step-no">
            1</div>
        <div class="step-dark-left">
            Administrator Details</div>
        <div class="step-dark-Round">
            &nbsp;</div>
        <div class="clear">
        </div>
    </div>
    <!--  end step-holder -->
    <!-- start id-form -->
    <% using (Html.BeginForm("Profile", "Admin", FormMethod.Post, new { id = "formProfile", @class = "validateforms" }))
       { %>
    <% = Html.HiddenFor(x => x.Admin.ID)%>
    <table border="0" cellpadding="0" cellspacing="0" class="tbl-form">
        <!-- start admin profile -->
        <tr>
            <th valign="middle" width="100px">
                <span class="mandate">*</span> User Name:
            </th>
            <td align="left" valign="middle">
                <%= Html.HiddenFor(model => model.Admin.UserName, new { @class = "validate[required] inp-form" })%>
                <%= Html.DisplayTextFor(model => model.Admin.UserName)%>
            </td>
            <td>
            </td>
        </tr>
        <tr>
            <th valign="middle" width="100px">
                <span class="mandate">*</span> Password:
            </th>
            <td align="left" valign="middle">
                <%= Html.PasswordFor(model => model.Admin.Password, new { @class = "validate[required] inp-form" })%>
            </td>
            <td>
            </td>
        </tr>
        <tr>
            <th valign="middle" width="100px">
                <span class="mandate">*</span> Super Admin:
            </th>
            <td align="left" valign="middle">
                <%= Html.DisplayTextFor(m => m.Admin.IsSupperAdmin)%>
            </td>
            <td>
            </td>
        </tr>
      
        <tr>
            <th valign="middle" name="status" id="Th1" class="required" width="100px">
                <span class="mandate">*</span> Role:
            </th>
            <td align="left" valign="middle">
                <div class="select_holder">
                     <%= Html.DisplayTextFor(m => m.Admin.Role)%>
                </div>
            </td>
            <td>
            </td>
        </tr>
        <!-- end admin -->
        <tr>
            <td colspan="3">
                &nbsp;
            </td>
        </tr>
        <!-- start Modules List -->
        <tr>
            <th valign="top">
                 Access Control:
            </th>
            <td>
                <div class="scrollbox" >
                    <ul>
                        <% 
                            foreach(var module in Model.Admin.Modules)
               
                            //for (int i = 0; i < this.Model.Admin.Modules.Count; i++)
                            {
                        %>
                        <li>
                            <%=module.ModuleName%>
                        </li>
                        <% }%>
                    </ul>
                </div>
            </td>
            <td>
            </td>
        </tr>
        <!-- end Modules List -->
         <tr>
            <td colspan="3" ><div class="form_divider"></div></td><!--------------------------------------------------------------------->
        </tr>
        

        <tr>
            <td colspan="3">&nbsp;</td>
        </tr>
        <tr>
            <th>
                &nbsp;
            </th>
            <td valign="top">
                <input type="submit" value="Submit"  onclick="checkForm();" class="buttons" style="margin-right:8px;float:left" />
                <input type="reset" value="Reset"  class="buttons" style="margin-right:8px;float:left"/>
            </td>
            <td>
            </td>
        </tr>
    </table>
    <%} %>
    <!-- end id-form  -->
                    
                    
                </div>
            </td>
            <td id="tbl-border-right">
            </td>
        </tr>
        <tr>
            <th class="sized bottomleft">
            </th>
            <td id="tbl-border-bottom">
                &nbsp;
            </td>
            <th class="sized bottomright">
            </th>
        </tr>
    </table>
    <!--  end table-content  -->
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="CSS" runat="server">
    <link href="<%=Url.Content("~/Scripts/qtip2/jquery.qtip.min.css") %>" rel="stylesheet"
        type="text/css" />
    <link href="<%=Url.Content("~/Scripts/jquery.validation/validationEngine.jquery.css")%>"
        rel="stylesheet" type="text/css" />
    <link href="<%=Url.Content("~/Scripts/chosen/chosen.css")%>" rel="stylesheet" type="text/css" />
    <link href="<%=Url.Content("~/Content/css/mod-listing.css")%>" rel="stylesheet" type="text/css" />
     <style type="text/css">
        .scrollbox
        {
            height:auto;
            min-width: 580px !important;
            line-height: 18px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="JS" runat="server">

    <script src="http://code.jquery.com/ui/1.9.2/jquery-ui.js" type="text/javascript"></script>

    <!-- -->

    <script src="<%=Url.Content("~/Scripts/jquery.validation/jquery.validationEngine-en.js")%>"
        type="text/javascript"></script>

    <script src="<%=Url.Content("~/Scripts/jquery.validation/jquery.validationEngine.js")%>"
        type="text/javascript"></script>

    <script src="<%=Url.Content("~/Scripts/chosen/chosen.jquery.min.js")%>" type="text/javascript"></script>

    <script src="<%=Url.Content("~/Scripts/knockout/knockout.js")%>" type="text/javascript"></script>

    <script src="<%=Url.Content("~/Scripts/knockout/knockout.mapping.js")%>" type="text/javascript"></script>

    <script language="javascript" type="text/javascript">
        $(document).ready(function() {
            $("#formID").validationEngine();
            $(".chzn-nosearch").chosen({ disable_search_threshold: 3 });
            $('li:odd').addClass("odd");
        });
    </script>

</asp:Content>

